#include<bits/stdc++.h>
using namespace std;
typedef long long ll;

const int MOD = 1e9+7;
const int MAXN = 5000;
ll fac[MAXN], inv_fac[MAXN];

ll quick_pow(ll a, ll b, ll mod) {
    ll res = 1;
    while (b) {
        if(b&1)res = res * a % mod; 
        a = a * a % mod;
        b >>= 1;
    }
    return res;
}

ll inv(ll a, ll m) {
    return quick_pow(a, m-2, m);
}

void init_comb() {
    fac[0] = 1;
    for (int i = 1; i < MAXN; ++i)
        fac[i] = fac[i-1] * i % MOD;
    inv_fac[MAXN-1] = inv(fac[MAXN-1], MOD);
    for (int i = MAXN-2; i >= 0; --i)
        inv_fac[i] = inv_fac[i+1] * (i+1) % MOD;
}

ll comb(int n, int k) {
    if (k < 0 || k > n) return 0;
    return fac[n] * inv_fac[k] % MOD * inv_fac[n-k] % MOD;
}

void solve(){
    ll n,k,m;
    cin>>n>>k>>m;
    ll res=comb(n,k)%MOD;
    res=res*quick_pow(m,k,MOD);
    cout<<res;
}

int main(){
	ios::sync_with_stdio(0);
	cin.tie(0),cout.tie(0);
    init_comb();
	int _=1;
	// cin>>_;
	while(_--){
		solve();
	}
	return 0;
}
